<template>
    <div id="ReputationManage">
       <el-row style="margin-bottom:20px">
           <el-col :span="2">
               <el-button type="primary" @click="pushToaddNewStudent">新增口碑</el-button>
           </el-col>
       </el-row>
        <table class="table table-bordered">
            <tbody>
                <tr>
                    <td>姓名</td>
                    <td>性别</td>
                    <td>电话</td>
                    <td>电子邮箱</td>
                    <td>QQ</td>
                    <td>微信</td>
                    <td>状态</td>
                    <td>报名科目</td>
                    <td>报名费</td>
                    <td>学费</td>
                    <td>咨询师</td>
                    <td>推荐费</td>
                    <td>毕业学校</td>
                    <td>毕业年限</td>
                    <td>学历</td>
                </tr>
                <tr v-for="(item,key) in studentInfos" :key="key">
                    <td>{{item.name}}</td>
                    <td>{{item.gender}}</td>
                    <td>{{item.mobile}}</td>
                    <td>{{item.email}}</td>
                    <td>{{item.qq}}</td>
                    <td>{{item.wx}}</td>
                    <td>{{item.status}}</td>
                    <td>{{item.subject}}</td>
                    <td>{{item.entryFee}}</td>
                    <td>{{item.tuitionFee}}</td>
                    <td>{{item.advisor}}</td>
                    <td>{{item.recommonendFee}}</td>
                    <td>{{item.graduateFrom}}</td>
                    <td>{{item.graduateYear}}</td>
                    <td>{{item.education}}</td>
                </tr>
            </tbody>
        </table>
    </div>
</template>
<script>
export default {
    data(){
        return {
            studentInfos:[{
                name: '',
                gender: '',
                mobile: '',
                email: '',
                qq: '',
                wx: '',
                status: '',
                subject: '',
                entryFee: '',
                tuitionFee: '',
                advisor: '',
                recommonendFee: '',
                graduateFrom: '',
                graduateYear: '',
                education: ''
            }]
        }
    },
    methods: {
        loadData(){
            var url = window.baseURL + "/backstage/reputation/findByPage?token="+this.$token;
            this.$http.get(url)
            .then((response)=>{
                this.studentInfos = response.data.data.list.results;
            })
            .catch((error)=>{
            })
        },
        pushToaddNewStudent(){
            this.$router.push({name:'AddNewReputationStudent'})
        }   
    },
    created(){
        this.loadData();
    }
}
</script>

<style lang="scss" scoped>
    #ReputationManage {
        width: 100%;
        height: 100%;
        padding: 40px;

    }
</style>
